(rcs2log, rcs-checkin, grep-changelog, vcdiff): Prepend "-" to the command,
authorEli Zaretskii <eliz@gnu.org>
Sat, 25 Aug 2007 10:58:54 +0000 (10:58 +0000)
committerEli Zaretskii <eliz@gnu.org>
Sat, 25 Aug 2007 10:58:54 +0000 (10:58 +0000)
in case srcdir=. and file is copied into itself.

lib-src/Makefile.in

index 1482ea6c5dfb7ac6b271548ab6033637907102ba..5d8da71dbdda743843c0e876d62c679dadd43f1b 100644 (file)
@@ -268,18 +268,21 @@ BASE_CFLAGS = C_SWITCH_SYSTEM C_SWITCH_MACHINE -DHAVE_CONFIG_H \
 all: ${DONT_INSTALL} ${UTILITIES} ${INSTALLABLES} ${SCRIPTS} ${INSTALLABLE_SCRIPTS}
 
 /* These targets copy the scripts into the build directory
-so that they can be run from there in an uninstalled Emacs.  */
+so that they can be run from there in an uninstalled Emacs.
+The "-" is prepended because some versions of cp barf when
+srcdir is the current directory, and thus the file will be
+copied into itself.  */
 rcs2log: $(srcdir)/rcs2log
-       cp -p $(srcdir)/rcs2log rcs2log
+       -cp -p $(srcdir)/rcs2log rcs2log
 
 rcs-checkin: $(srcdir)/rcs-checkin
-       cp -p $(srcdir)/rcs-checkin rcs-checkin
+       -cp -p $(srcdir)/rcs-checkin rcs-checkin
 
 grep-changelog: $(srcdir)/grep-changelog
-       cp -p $(srcdir)/grep-changelog grep-changelog
+       -cp -p $(srcdir)/grep-changelog grep-changelog
 
 vcdiff: $(srcdir)/vcdiff
-       cp -p $(srcdir)/vcdiff vcdiff
+       -cp -p $(srcdir)/vcdiff vcdiff
 
 #ifdef MOVEMAIL_NEEDS_BLESSING
 blessmail: